package com.example.nettydemo;

import com.example.nettydemo.tcpserver.VoIpTcpServer;
import org.springframework.boot.CommandLineRunner;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

@SpringBootApplication
public class NettydemoApplication implements CommandLineRunner {

	public static void main(String[] args) {
		SpringApplication.run(NettydemoApplication.class, args);
	}

	@Override
	public void run(String... args) throws Exception {
		VoIpTcpServer server = new VoIpTcpServer(9211);
		server.run(); // 启动服务器
	}
}
